package com.ikun.admin.websocket.message;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

/**
 * @ClassName WebSocketMessage
 * @Description:
 * @CreateDate: 2024/9/6 16:47
 */
@Data
@ApiModel("WebSocket消息")
public class WebSocketMessage {

    @ApiModelProperty("数据类型 0系统消息  1 用户消息")
    private Integer messageType;

    @ApiModelProperty("消息来源")
    private Long from;

    @ApiModelProperty("消息接收者")
    private Long to;

    @ApiModelProperty("token")
    private String token;

    @ApiModelProperty("消息内容")
    private Message message;

    @Data
    public static class Message {

        private String content;

        private byte[] file;
    }
}
